package weixinkeji.dev.power.view.tmp;

import com.alibaba.fastjson.JSON;
import java.util.HashSet;
import java.util.Set;
import weixinkeji.dev.power.view.bean.UserPowerMenuTree;

/**
 *
 * @author IMY
 */
public class UserMenuPowerData {

    private final Set<UserPowerMenuTree> menu = new HashSet<>();
    
    public void put(String id, String pid, String name, String url, boolean isexpand) {
        menu.add(new UserPowerMenuTree(id, pid, name, url, isexpand));
    }

    public String getMenuToJson() {
        return JSON.toJSONString(menu);
    }
}
